﻿using ExpressesClass.BestApi.Utils;
using ExpressesClass.StoApi.Base;
using ExpressesClass.StoApi.billStock.response;
using ExpressesClass.StoApi.Util;

namespace ExpressesClass.StoApi.billStock.request
{
    public class BillStockReq : StoRequest
    {
        public BillStockReq()
        {
            this.siteCode = "";
            this.userCode = "";
            this.userType = "";
            this.password = "";
            this.timestamp = "";
        }
        public string siteCode { get; set; }
        public string userCode { get; set; }
        public string userType { get; set; }
        public string password { get; set; }
        public string timestamp { get; set; }

        public override string GetApiName()
        {
            return ConfigUrl.GetApiName("STOCK");
        }

        public override string GetKeyName()
        {
            return ConfigUrl.GetKeyName("STOCK");
        }

        public override string GetUrl()
        {
            return ConfigUrl.GetUrl("STOCK");
        }

        public override StoResponse makeResponse(string rsp)
        {
            return JsonParser.jsonToObj<BillStockRsp>(rsp);
        }
    }
}
